package com.jsoft.android.exp.ffxiii;

import java.util.HashMap;
import java.util.Map;


public class Inventory {

	
	// 
	/*
	 * ask for a character's weapons
	 * or for the character's weapon group
	 * 
	 * and hold all the data
	 */
	
	static Weapon currentWeapon;
	
	static Weapon getCurrentWeapon() {
		return currentWeapon;
	}

	static void setCurrentWeapon(Weapon currentWeapon) {
		Inventory.currentWeapon = currentWeapon;
		Exp.mCurrentLv = getCurrentWeapon().getBaseLevel();
		
		Exp.mTargetLv = getCurrentWeapon().getTargetLevel();

		Exp.mCurrentEXP = getCurrentWeapon().getStartingEXP();

	}

	static WeaponGroup currentWeaponTier;
	
	public static WeaponGroup getCurrentWeaponTier() {
		return currentWeaponTier;
	}

	public static void setCurrentWeaponTier(WeaponGroup currentWeaponTier) {
		Inventory.currentWeaponTier = currentWeaponTier;
		setCurrentWeapon(currentWeaponTier.getTier1());
	}

	static WeaponGroup[] currentWeapons;


	public static WeaponGroup[] getCurrentWeapons() {
		return currentWeapons;
	}

	public static void setCurrentWeapons(WeaponGroup[] newCurrentWeapons) {
		setCurrentWeapon(newCurrentWeapons[0].getTier1()); // static?
		//
		currentWeapons = newCurrentWeapons;
	}
		
		static WeaponGroup[] wgLightning = {
				new WeaponGroup(new Weapon("Blazefire Saber", "Lightning", 1, 26, 300, 0, 57, 15, 4, 15, 4),
				new Weapon("Flamberge", "Lightning", 10, 61, 1500, 3435, 215, 23, 5, 23, 5),
				new Weapon("Omega Weapon", "Lightning", 47, 100, 3300, 16962, 297, 26, 6, 26, 6)),

				new WeaponGroup(new Weapon("Axis Blade", "Lightning", 1, 21, 1200, 0, 225, 8, 2, 8, 2),
				new Weapon("Enkindler", "Lightning", 13, 41, 3600, 6732, 261, 13, 3, 13, 3),
				new Weapon("Omega Weapon", "Lightning", 39, 100, 3300, 14586, 297, 18, 3, 18, 3)),

				new WeaponGroup(new Weapon("Edged Carbine", "Lightning", 1, 26, 420, 0, 75, 8, 3, 20, 6),
				new Weapon("Razor Carbine", "Lightning", 13, 61, 1500, 4080, 215, 10, 3, 28, 7),
				new Weapon("Omega Weapon", "Lightning", 47, 100, 3300, 16962, 297, 12, 2, 30, 7)),

				new WeaponGroup(new Weapon("Lifesaber", "Lightning", 1, 21, 1500, 0, 215, 8, 4, 8, 4),
				new Weapon("Peacemaker", "Lightning", 16, 41, 3000, 6600, 240, 25, 5, 25, 5),
				new Weapon("Omega Weapon", "Lightning", 37, 100, 3300, 13992, 297, 25, 5, 25, 5)),

				new WeaponGroup(new Weapon("Gladius", "Lightning", 1, 26, 800, 0, 116, 25, 6, 13, 3),
				new Weapon("Helter-skelter", "Lightning", 19, 61, 1500, 4524, 168, 28, 7, 10, 3),
				new Weapon("Omega Weapon", "Lightning", 42, 100, 3300, 15477, 297, 30, 7, 12, 2)),

				new WeaponGroup(new Weapon("Organyx", "Lightning", 1, 26, 300, 0, 42, 37, 6, 37, 6),
				new Weapon("Apocalypse", "Lightning", 14, 61, 800, 2308, 116, 50, 6, 50, 6),
				new Weapon("Omega Weapon", "Lightning", 33, 100, 3300, 12804, 297, 57, 7, 57, 7)),

				new WeaponGroup(new Weapon("Hauteclaire", "Lightning", 1, 26, 800, 0, 116, 13, 5, 13, 5),
				new Weapon("Durandal", "Lightning", 19, 61, 1500, 4524, 168, 18, 6, 18, 6),
				new Weapon("Omega Weapon", "Lightning", 42, 100, 3300, 15477, 297, 18, 7, 18, 7)),

				new WeaponGroup(new Weapon("Lionheart", "Lightning", 1, 21, 1500, 0, 174, 8, 3, 8, 3),
				new Weapon("Ultima Weapon", "Lightning", 15, 41, 2600, 5848, 232, 13, 5, 13, 5),
				new Weapon("Omega Weapon", "Lightning", 35, 100, 3300, 13398, 297, 13, 5, 13, 5)),

				};

				static WeaponGroup[] wgSazh = {
				new WeaponGroup(new Weapon("Vega 42s", "Sazh", 1, 26, 300, 0, 57, 12, 5, 14, 5),
				new Weapon("Altairs", "Sazh", 10, 61, 1500, 3435, 215, 20, 6, 30, 6),
				new Weapon("Total Eclipses", "Sazh", 45, 100, 2640, 18612, 363, 20, 8, 30, 8)),

				new WeaponGroup(new Weapon("Spica Defenders", "Sazh", 1, 21, 1200, 0, 225, 6, 2, 15, 4),
				new Weapon("Sirius Sidearms", "Sazh", 16, 41, 2600, 6080, 232, 20, 3, 20, 5),
				new Weapon("Total Eclipses", "Sazh", 34, 100, 2640, 14619, 363, 20, 7, 20, 9)),

				new WeaponGroup(new Weapon("Deneb Duelers", "Sazh", 1, 26, 420, 0, 75, 8, 4, 24, 9),
				new Weapon("Canopus AMPs", "Sazh", 13, 61, 1500, 4080, 215, 14, 6, 36, 10),
				new Weapon("Total Eclipses", "Sazh", 45, 100, 2640, 18612, 363, 14, 6, 36, 11)),

				new WeaponGroup(new Weapon("Rigels", "Sazh", 1, 26, 800, 0, 116, 10, 6, 15, 6),
				new Weapon("Polaris Specials", "Sazh", 19, 61, 1500, 4524, 168, 16, 8, 24, 8),
				new Weapon("Total Eclipses", "Sazh", 40, 100, 2640, 16797, 363, 16, 10, 24, 10)),

				new WeaponGroup(new Weapon("Aldebarans", "Sazh", 1, 26, 300, 0, 42, 0, 0, 40, 9),
				new Weapon("Sadalmeliks", "Sazh", 14, 61, 800, 2308, 116, 0, 0, 60, 10),
				new Weapon("Total Eclipses", "Sazh", 32, 100, 2640, 13893, 363, 0, 0, 61, 11)),

				new WeaponGroup(new Weapon("Pleiades Hi-Powers", "Sazh", 1, 26, 420, 0, 75, 40, 12, 0, 0),
				new Weapon("Hyades Magnums", "Sazh", 13, 61, 1500, 4080, 215, 60, 18, 0, 0),
				new Weapon("Total Eclipses", "Sazh", 45, 100, 2640, 18612, 363, 61, 11, 0, 0)),

				new WeaponGroup(new Weapon("Antares Deluxes", "Sazh", 1, 21, 800, 0, 116, 12, 4, 18, 4),
				new Weapon("Fomalhaut Elites", "Sazh", 15, 41, 1500, 3852, 168, 16, 5, 22, 5),
				new Weapon("Total Eclipses", "Sazh", 27, 100, 2640, 12078, 363, 16, 6, 22, 6)),

				new WeaponGroup(new Weapon("Procyons", "Sazh", 1, 21, 1500, 0, 174, 14, 4, 9, 2),
				new Weapon("Betelgeuse Customs", "Sazh", 15, 61, 2600, 6240, 260, 20, 6, 18, 3),
				new Weapon("Total Eclipses", "Sazh", 35, 100, 2640, 14982, 363, 26, 6, 18, 4)),

				};

				static WeaponGroup[] wgSnow = {
				new WeaponGroup(new Weapon("Wild Bear", "Snow", 1, 26, 300, 0, 57, 15, 5, 15, 5),
				new Weapon("Feral Pride", "Snow", 10, 61, 1500, 3435, 215, 23, 6, 23, 6),
				new Weapon("Save the Queen", "Snow", 48, 100, 3333, 16775, 286, 24, 7, 24, 7)),

				new WeaponGroup(new Weapon("Paladin", "Snow", 1, 21, 1200, 0, 225, 8, 4, 8, 4),
				new Weapon("Winged Saint", "Snow", 16, 41, 2600, 6080, 232, 13, 5, 13, 5),
				new Weapon("Save the Queen", "Snow", 35, 100, 3333, 13057, 286, 15, 5, 15, 6)),

				new WeaponGroup(new Weapon("Rebel Heart", "Snow", 1, 21, 800, 0, 116, 5, 3, 10, 3),
				new Weapon("Warrior's Emblem", "Snow", 15, 41, 1500, 3852, 168, 8, 6, 17, 6),
				new Weapon("Save the Queen", "Snow", 28, 100, 3333, 11055, 286, 8, 6, 17, 6)),

				new WeaponGroup(new Weapon("Power Circle", "Snow", 1, 26, 1500, 0, 174, 23, 7, 13, 1),
				new Weapon("Battle Standard", "Snow", 20, 61, 2600, 7008, 232, 33, 8, 5, 2),
				new Weapon("Save the Queen", "Snow", 53, 100, 3333, 18205, 286, 34, 9, 4, 2)),

				new WeaponGroup(new Weapon("Feymark", "Snow", 1, 21, 800, 0, 116, 0, 0, 30, 5),
				new Weapon("Soul Blazer", "Snow", 15, 41, 1500, 3852, 168, 0, 0, 60, 6),
				new Weapon("Save the Queen", "Snow", 28, 100, 3333, 11055, 286, 0, 0, 60, 10)),

				new WeaponGroup(new Weapon("Sacrificial Circle", "Snow", 1, 26, 1500, 0, 174, 41, 9, 41, 9),
				new Weapon("Indomitus", "Snow", 20, 61, 2600, 7008, 232, 25, 9, 25, 9),
				new Weapon("Save the Queen", "Snow", 53, 100, 3333, 18205, 286, 30, 10, 30, 10)),

				new WeaponGroup(new Weapon("Unsetting Sun", "Snow", 1, 26, 420, 0, 75, 18, 6, 3, 2),
				new Weapon("Midnight Sun", "Snow", 14, 61, 1285, 4080, 215, 23, 8, 6, 2),
				new Weapon("Save the Queen", "Snow", 48, 100, 3333, 16775, 286, 23, 8, 7, 2)),

				new WeaponGroup(new Weapon("Umbra", "Snow", 1, 21, 1200, 0, 225, 13, 3, 20, 5),
				new Weapon("Solaris", "Snow", 13, 41, 3600, 6732, 261, 15, 4, 25, 6),
				new Weapon("Save the Queen", "Snow", 40, 100, 3333, 14487, 286, 14, 4, 26, 6)),

				};

				static WeaponGroup[] wgHope = {
				new WeaponGroup(new Weapon("Airwing", "Hope", 1, 21, 400, 0, 76, 18, 4, 12, 3),
				new Weapon("Skycutter", "Hope", 10, 41, 3012, 3012, 168, 31, 5, 45, 4),
				new Weapon("Nue", "Hope", 28, 100, 10384, 10384, 242, 31, 5, 45, 4)),

				new WeaponGroup(new Weapon("Hawkeye", "Hope", 1, 26, 420, 0, 75, 2, 1, 18, 7),
				new Weapon("Eagletalon", "Hope", 13, 61, 1500, 4080, 215, 4, 2, 26, 8),
				new Weapon("Nue", "Hope", 49, 100, 3850, 15466, 242, 4, 2, 26, 9)),

				new WeaponGroup(new Weapon("Otshirvani", "Hope", 1, 21, 420, 0, 75, 6, 3, 14, 5),
				new Weapon("Urubutsin", "Hope", 16, 41, 2600, 6080, 232, 18, 4, 20, 6),
				new Weapon("Nue", "Hope", 36, 100, 3850, 12320, 242, 18, 5, 20, 7)),

				new WeaponGroup(new Weapon("Ninurta", "Hope", 1, 26, 420, 0, 75, 12, 5, 12, 5),
				new Weapon("Jatayu", "Hope", 13, 61, 1500, 4080, 215, 18, 6, 18, 6),
				new Weapon("Nue", "Hope", 49, 100, 3850, 15466, 242, 18, 6, 18, 6)),

				new WeaponGroup(new Weapon("Vidofnir", "Hope", 1, 21, 1200, 0, 225, 6, 2, 14, 6),
				new Weapon("Hresvelgr", "Hope", 16, 41, 2600, 6080, 232, 8, 3, 20, 7),
				new Weapon("Nue", "Hope", 36, 100, 3850, 12320, 242, 8, 3, 20, 7)),

				new WeaponGroup(new Weapon("Simurgh", "Hope", 1, 21, 800, 0, 116, 28, 7, 0, 0),
				new Weapon("Tezcatlipoca", "Hope", 15, 61, 1500, 3852, 168, 35, 9, 0, 0),
				new Weapon("Nue", "Hope", 28, 100, 3850, 10384, 242, 35, 9, 0, 0)),

				new WeaponGroup(new Weapon("Malphas", "Hope", 1, 26, 420, 0, 75, 30, 7, 30, 7),
				new Weapon("Naberius", "Hope", 13, 61, 1488, 4080, 216, 40, 8, 40, 8),
				new Weapon("Nue", "Hope", 49, 100, 3850, 15466, 242, 40, 8, 40, 8)),

				new WeaponGroup(new Weapon("Alicanto", "Hope", 1, 26, 800, 0, 116, 10, 4, 10, 4),
				new Weapon("Caladrius", "Hope", 19, 41, 1500, 4524, 168, 14, 6, 14, 6),
				new Weapon("Nue", "Hope", 44, 100, 3850, 14256, 242, 14, 6, 14, 6)),

				};

				static WeaponGroup[] wgVanelle = {
				new WeaponGroup(new Weapon("Binding Rod", "Vanelle", 1, 26, 300, 0, 57, 18, 6, 12, 1),
				new Weapon("Hunter's Rod", "Vanelle", 10, 61, 1500, 3435, 215, 22, 7, 18, 2),
				new Weapon("Nirvana", "Vanelle", 45, 100, 3740, 17292, 308, 22, 7, 18, 2)),

				new WeaponGroup(new Weapon("Tigerclaw", "Vanelle", 1, 26, 300, 0, 42, 23, 7, 23, 7),
				new Weapon("Wyrmfang", "Vanelle", 14, 61, 800, 2308, 116, 36, 8, 36, 8),
				new Weapon("Nirvana", "Vanelle", 31, 100, 3740, 12980, 308, 36, 8, 36, 8)),

				new WeaponGroup(new Weapon("Healer's Staff", "Vanelle", 1, 21, 2000, 0, 125, 8, 2, 8, 2),
				new Weapon("Physician's Staff", "Vanelle", 16, 41, 2115, 5895, 252, 20, 4, 20, 4),
				new Weapon("Nirvana", "Vanelle", 33, 100, 3740, 13596, 308, 28, 4, 28, 4)),

				new WeaponGroup(new Weapon("Pearlwing Staff", "Vanelle", 1, 26, 420, 0, 75, 2, 1, 15, 5),
				new Weapon("Brightwing Staff", "Vanelle", 13, 61, 1500, 4080, 215, 3, 2, 21, 6),
				new Weapon("Nirvana", "Vanelle", 45, 100, 3740, 17292, 308, 3, 2, 21, 9)),

				new WeaponGroup(new Weapon("Rod of Thorns", "Vanelle", 1, 26, 420, 0, 75, 6, 5, 6, 5),
				new Weapon("Orochi Rod", "Vanelle", 13, 61, 1500, 4080, 215, 16, 7, 16, 7),
				new Weapon("Nirvana", "Vanelle", 45, 100, 3740, 17292, 308, 16, 7, 16, 7)),

				new WeaponGroup(new Weapon("Mistilteinn", "Vanelle", 1, 21, 800, 0, 116, 5, 3, 11, 6),
				new Weapon("Erinye's Cane", "Vanelle", 16, 41, 1332, 3852, 168, 7, 4, 15, 8),
				new Weapon("Nirvana", "Vanelle", 33, 100, 1584, 11440, 308, 7, 4, 15, 8)),

				new WeaponGroup(new Weapon("Belladonna Wand", "Vanelle", 1, 21, 800, 0, 116, 5, 3, 11, 6),
				new Weapon("Malboro Wand", "Vanelle", 15, 41, 1500, 3852, 168, 7, 4, 15, 8),
				new Weapon("Nirvana", "Vanelle", 26, 100, 3740, 11440, 308, 7, 4, 15, 8)),

				new WeaponGroup(new Weapon("Heavenly Axis", "Vanelle", 1, 26, 800, 0, 116, 5, 3, 11, 6),
				new Weapon("Abraxas", "Vanelle", 19, 61, 1500, 4524, 168, 7, 4, 15, 8),
				new Weapon("Nirvana", "Vanelle", 40, 100, 3740, 15752, 308, 7, 4, 15, 8)),

				};

				static WeaponGroup[] wgFang = {
				new WeaponGroup(new Weapon("Bladed Lance", "Fang", 1, 26, 300, 0, 57, 55, 3, 35, 2),
				new Weapon("Glaive", "Fang", 10, 61, 1500, 3435, 215, 60, 4, 17, 2),
				new Weapon("Kain's Lance", "Fang", 46, 100, 4400, 16775, 275, 60, 7, 17, 3)),

				new WeaponGroup(new Weapon("Dragoon Lance", "Fang", 1, 21, 800, 0, 116, 39, 7, 0, 0),
				new Weapon("Dragonhorn", "Fang", 14, 41, 2076, 3870, 138, 65, 8, 0, 0),
				new Weapon("Kain's Lance", "Fang", 25, 100, 4400, 11000, 275, 71, 9, 0, 0)),

				new WeaponGroup(new Weapon("Partisan", "Fang", 1, 26, 420, 0, 75, 6, 1, 39, 6),
				new Weapon("Rhomphaia", "Fang", 14, 61, 1730, 3225, 115, 10, 2, 47, 7),
				new Weapon("Kain's Lance", "Fang", 35, 100, 4400, 13750, 275, 10, 3, 47, 8)),

				new WeaponGroup(new Weapon("Shamanic Spear", "Fang", 1, 21, 800, 0, 116, 0, 0, 47, 7),
				new Weapon("Heretic's Halberd", "Fang", 15, 41, 1500, 3852, 168, 0, 0, 50, 8),
				new Weapon("Kain's Lance", "Fang", 25, 100, 4400, 11000, 275, 0, 0, 50, 9)),

				new WeaponGroup(new Weapon("Punisher", "Fang", 1, 21, 1500, 0, 215, 20, 4, 31, 6),
				new Weapon("Banescissor Spear", "Fang", 17, 41, 2760, 6600, 240, 22, 5, 38, 7),
				new Weapon("Kain's Lance", "Fang", 33, 100, 4950, 13750, 275, 22, 5, 38, 7)),

				new WeaponGroup(new Weapon("Pandoran Spear", "Fang", 1, 21, 1500, 0, 215, 20, 4, 31, 6),
				new Weapon("Calamity Spear", "Fang", 16, 41, 3000, 6600, 240, 22, 5, 38, 7),
				new Weapon("Kain's Lance", "Fang", 35, 100, 4400, 13750, 275, 22, 6, 38, 8)),

				new WeaponGroup(new Weapon("Taming Pole", "Fang", 1, 26, 800, 0, 116, 23, 5, 23, 5),
				new Weapon("Venus Gospel", "Fang", 19, 61, 2136, 6312, 232, 30, 6, 30, 6),
				new Weapon("Kain's Lance", "Fang", 40, 100, 2475, 13200, 275, 30, 9, 30, 9)),

				new WeaponGroup(new Weapon("Gae Bolg", "Fang", 1, 21, 1500, 0, 215, 23, 4, 12, 4),
				new Weapon("Gungnir", "Fang", 17, 41, 2600, 6312, 232, 30, 5, 20, 5),
				new Weapon("Kain's Lance", "Fang", 33, 100, 4400, 13200, 275, 48, 6, 48, 6)),

				};
		

			    
				static Map<String, WeaponGroup[]> awg = new HashMap<String, WeaponGroup[]>();

				static {
					awg.put("Lightning", wgLightning);
					awg.put("Sazh", wgSazh);
					awg.put("Snow", wgSnow);
					awg.put("Hope", wgHope);
					awg.put("Vanelle", wgVanelle);
					awg.put("Fang", wgFang);
			}
				
				public static WeaponGroup[] getAwg(String who) {
					//String arf = awg.get("Lightning")[1].getTier1().getName();
					//WeaponGroup[] arfarf = awg.get("Lightning");
					//return arfarf;
					return awg.get(who);
				}
				
				
	

}
